package com.jcooky.tutorfs.proxy.protocol;

import org.apache.mina.core.buffer.IoBuffer;

public class ResRead extends AbstractMessage {
	private byte []data;
	private int size;

	public void fromBytes(IoBuffer buf) {
		throw new UnsupportedOperationException();
	}

	public void toBytes(IoBuffer buf) {
		buf.put(data);
		buf.putInt(size);
	}

	public int length() {
		return 256 + 4;
	}

	public byte[] getData() {
		return data;
	}

	public void setData(byte[] data) {
		this.data = data;
	}

	public int getSize() {
		return size;
	}

	public void setSize(int size) {
		this.size = size;
	}
	
	
}
